SetScrap command

Syntax
SetScrap data, resourceType

Description
Puts data on the Clipboard as the specified resource type. Use GetScrap and SetScrap instead of the Clipboard system variable when you want to work with data types other than plain text.

Examples
SetScrap "just some words", "TEXT"
SetScrap pictData, "PICT"

// Get a TEXT/styl (styled text) resource pair from a file and put the styled text on the Clipboard
Variable theText, theStyle, theFile
theFile = "Mac HD:Desktop Folder:My Resource File"
theText = GetResource theFile, "TEXT", 128
theStyle = GetResource theFile, "styl", 128
SetScrap theText, "TEXT"
SetScrap theStyle, "styl"

Author Info
SetScrap, part of Scrap Extension
Copyright © 1999 Life OnLine Software (lr). All rights reserved.